<div class="form">

<?php $form=$this->beginWidget('CActiveForm', array(
	'id'=>'tempresas-form',
	'enableAjaxValidation'=>false,
)); ?>

	<p class="note">Campos con <span class="required">*</span> son requeridos.</p>

	<?php echo $form->errorSummary($model); ?>


	<div class="row">
		<?php echo $form->labelEx($model,'codigo'); ?>
		<?php echo $form->textField($model,'codigo',array('size'=>20,'maxlength'=>20,'readonly'=>!$model->isNewRecord)); ?>
		<?php echo $form->error($model,'codigo'); ?>
	</div>
	

	<div class="row">
		<?php echo $form->labelEx($model,'rif'); ?>
		<?php echo $form->textField($model,'rif',array('size'=>30,'maxlength'=>30)); ?>
		<?php echo $form->error($model,'rif'); ?>
	</div>

	<div class="row">
		<?php echo $form->labelEx($model,'razon'); ?>
		<?php echo $form->textField($model,'razon',array('size'=>60,'maxlength'=>100)); ?>
		<?php echo $form->error($model,'razon'); ?>
	</div>

	<div class="row">
		<?php echo $form->labelEx($model,'nombrecomercial'); ?>
		<?php echo $form->textField($model,'nombrecomercial',array('size'=>60,'maxlength'=>200)); ?>
		<?php echo $form->error($model,'nombrecomercial'); ?>
	</div>

	<div class="row">
		<?php echo $form->labelEx($model,'tipoCompania'); ?>
		<?php echo $form->dropDownList($model,'tipoCompania',TUtilidades::obtenerTipoCompania(),array('empty'=>'--Seleccione--')); ?>
		<?php echo $form->error($model,'tipoCompania'); ?>
	</div>

	<div class="row">
		<?php echo $form->labelEx($model,'correo'); ?>
		<?php echo $form->textField($model,'correo',array('size'=>60,'maxlength'=>75)); ?>
		<?php echo $form->error($model,'correo'); ?>
	</div>

	<div class="row">
		<?php echo $form->labelEx($model,'domicilio'); ?>
		<?php echo $form->textField($model,'domicilio',array('size'=>60,'maxlength'=>300)); ?>
		<?php echo $form->error($model,'domicilio'); ?>
	</div>

	<div class="row">
		<?php echo $form->labelEx($model,'usuarios_login'); ?>
		<?php echo $form->dropDownList($model,'usuarios_login',TUtilidades::obtenerAsistentes(),array('empty'=>'--Seleccione--')); ?>
		<?php echo $form->error($model,'usuarios_login'); ?>
	</div>


	<div class="row buttons">
		<?php echo CHtml::submitButton($model->isNewRecord ? 'Crear Empresa' : 'Guardar'); ?>
	</div>

<?php $this->endWidget(); ?>

</div><!-- form -->